<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title th:text="${msg}">Title</title>
    <link rel="stylesheet" type="text/css" media="all" th:href="@{/css/test.css}">
</head>
<body>

<div th:text="${book}">


</div>
<div th:utext="${html}"></div>
<p th:text="这是一个测试"></p>
<p th:text="'这是一个测试2'+'字符串拼接'"></p>
<p th:text="|The name is ${book.bookName}|"></p>
<p th:text="${1==1}? 'even' : 'odd'"></p>
<div th:attr="class=${msg}"></div>
<button th:onclick="add(${book.getBookId()})">点击</button>

<p id="text">hello,do you need [[${book.bookName}]] ?</p>


<script th:inline="javascript">

   //  let bookname = document.querySelector("#text").innerText;
   //
   // let list = bookname.split(" ");

   let name = /*[[${book.bookName}]]*/ defual;

    console.log(name)
</script>

</body>
</html>